﻿<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8" />
    <title>HelloWorld: src/main/java/com/stateforge/statemachine/examples/HelloWorld/HelloWorld.java Source File</title>
    <link href="/Content/Help.css" rel="stylesheet" type="text/css" />
    <link href="/Content/css/tabs.css" rel="stylesheet" type="text/css" />
    <link href="/Content/css/doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
    <div id="header">
        <img id="logo" alt="StateForge" src="/Content/Images/StateForgeLogo.png" />
        <div id="title">
            <h1>
                Examples using state machines generated by StateBuilderJava
            </h1>
            <h3>
                HelloWorld: src/main/java/com/stateforge/statemachine/examples/HelloWorld/HelloWorld.java Source File
            </h3>
        </div>
        <div id="menucontainer">
            <ul id="menu">
                <li><a href="/">Home</a></li>
                <li><a href="/Home/Download">Downloads</a></li>
                <li><a href="/Help/state-machine-tools.aspx">Help</a></li>
                <li><a href="/Home/Faq">F.A.Q</a></li>
                <li><a href="/Home/About">Contact us</a></li>
            </ul>
        </div>
    </div>
<!-- Generated by Doxygen 1.7.4 -->
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="namespaces.html"><span>Packages</span></a></li>
      <li><a href="annotated.html"><span>Classes</span></a></li>
      <li class="current"><a href="files.html"><span>Files</span></a></li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="files.html"><span>File&#160;List</span></a></li>
    </ul>
  </div>
<div class="header">
  <div class="headertitle">
<div class="title">src/main/java/com/stateforge/statemachine/examples/HelloWorld/HelloWorld.java</div>  </div>
</div>
<div class="contents">
<a href="_hello_world_8java.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a><a class="code" href="namespacecom_1_1stateforge_1_1statemachine_1_1examples_1_1_hello_world.html">00001</a> <span class="keyword">package </span>com.stateforge.statemachine.examples.HelloWorld;
<a name="l00002"></a>00002 
<a name="l00003"></a>00003 <span class="comment">//import com.stateforge.statemachine.examples.HelloWorld.HelloWorldConte;</span>
<a name="l00004"></a>00004 
<a name="l00009"></a><a class="code" href="classcom_1_1stateforge_1_1statemachine_1_1examples_1_1_hello_world_1_1_hello_world.html">00009</a> <span class="keyword">public</span> <span class="keyword">class </span><a class="code" href="classcom_1_1stateforge_1_1statemachine_1_1examples_1_1_hello_world_1_1_hello_world.html">HelloWorld</a>
<a name="l00010"></a>00010 {
<a name="l00011"></a><a class="code" href="classcom_1_1stateforge_1_1statemachine_1_1examples_1_1_hello_world_1_1_hello_world.html#a29039e8cc3b9deb2a297ad7450712db2">00011</a>         <span class="keyword">private</span> <a class="code" href="classcom_1_1stateforge_1_1statemachine_1_1examples_1_1_hello_world_1_1_hello_world_action.html">HelloWorldAction</a> <a class="code" href="classcom_1_1stateforge_1_1statemachine_1_1examples_1_1_hello_world_1_1_hello_world.html#a29039e8cc3b9deb2a297ad7450712db2">action</a>;
<a name="l00012"></a><a class="code" href="classcom_1_1stateforge_1_1statemachine_1_1examples_1_1_hello_world_1_1_hello_world.html#aabc4d2ec08a64e0595cfa59a59b0890c">00012</a>         <span class="keyword">private</span> HelloWorldContext <a class="code" href="classcom_1_1stateforge_1_1statemachine_1_1examples_1_1_hello_world_1_1_hello_world.html#aabc4d2ec08a64e0595cfa59a59b0890c">context</a>;
<a name="l00013"></a>00013         
<a name="l00014"></a><a class="code" href="classcom_1_1stateforge_1_1statemachine_1_1examples_1_1_hello_world_1_1_hello_world.html#af3090b556ca7265a0ee5703c503af87d">00014</a>         <span class="keyword">public</span> <a class="code" href="classcom_1_1stateforge_1_1statemachine_1_1examples_1_1_hello_world_1_1_hello_world.html#af3090b556ca7265a0ee5703c503af87d">HelloWorld</a>(){
<a name="l00015"></a>00015                 this.<a class="code" href="classcom_1_1stateforge_1_1statemachine_1_1examples_1_1_hello_world_1_1_hello_world.html#a29039e8cc3b9deb2a297ad7450712db2">action</a> = <span class="keyword">new</span> <a class="code" href="classcom_1_1stateforge_1_1statemachine_1_1examples_1_1_hello_world_1_1_hello_world_action.html">HelloWorldAction</a>();
<a name="l00016"></a>00016                 this.<a class="code" href="classcom_1_1stateforge_1_1statemachine_1_1examples_1_1_hello_world_1_1_hello_world.html#aabc4d2ec08a64e0595cfa59a59b0890c">context</a> = <span class="keyword">new</span> HelloWorldContext(this.<a class="code" href="classcom_1_1stateforge_1_1statemachine_1_1examples_1_1_hello_world_1_1_hello_world.html#a29039e8cc3b9deb2a297ad7450712db2">action</a>);
<a name="l00017"></a>00017         }
<a name="l00018"></a>00018         
<a name="l00019"></a><a class="code" href="classcom_1_1stateforge_1_1statemachine_1_1examples_1_1_hello_world_1_1_hello_world.html#a01ab72f5bab7ca5d32587bf8a00e538d">00019</a>     <span class="keyword">public</span> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="classcom_1_1stateforge_1_1statemachine_1_1examples_1_1_hello_world_1_1_hello_world.html#a01ab72f5bab7ca5d32587bf8a00e538d">main</a>( String[] args )
<a name="l00020"></a>00020     {
<a name="l00021"></a>00021         System.out.println( <span class="stringliteral">&quot;Hello World!&quot;</span> );
<a name="l00022"></a>00022     }
<a name="l00023"></a>00023      
<a name="l00024"></a><a class="code" href="classcom_1_1stateforge_1_1statemachine_1_1examples_1_1_hello_world_1_1_hello_world.html#af5975788b8443d1a0ec70f2889d3c808">00024</a>     <span class="keyword">public</span> <span class="keywordtype">void</span> <a class="code" href="classcom_1_1stateforge_1_1statemachine_1_1examples_1_1_hello_world_1_1_hello_world.html#af5975788b8443d1a0ec70f2889d3c808">start</a>(){
<a name="l00025"></a>00025         this.<a class="code" href="classcom_1_1stateforge_1_1statemachine_1_1examples_1_1_hello_world_1_1_hello_world.html#aabc4d2ec08a64e0595cfa59a59b0890c">context</a>.start();
<a name="l00026"></a>00026     }
<a name="l00027"></a>00027     
<a name="l00028"></a><a class="code" href="classcom_1_1stateforge_1_1statemachine_1_1examples_1_1_hello_world_1_1_hello_world.html#a5c44be869a1a4b9a1e2d0f8c23129889">00028</a>     <span class="keyword">public</span> <span class="keywordtype">void</span> <a class="code" href="classcom_1_1stateforge_1_1statemachine_1_1examples_1_1_hello_world_1_1_hello_world.html#a5c44be869a1a4b9a1e2d0f8c23129889">stop</a>(){
<a name="l00029"></a>00029         this.<a class="code" href="classcom_1_1stateforge_1_1statemachine_1_1examples_1_1_hello_world_1_1_hello_world.html#aabc4d2ec08a64e0595cfa59a59b0890c">context</a>.stop();
<a name="l00030"></a>00030     }
<a name="l00031"></a>00031     
<a name="l00032"></a>00032 }
</pre></div></div>
</div>
﻿<div id="footer">
    <hr />
    <p>
        Copyright &copy; 2011 StateForge.</p>
    <hr />
</div>
</body> </html> 
